package org.csu.mypetstore.persistence;

import org.apache.ibatis.annotations.Param;
import org.csu.mypetstore.domain.Account;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CartMapper {

    List<String>getItems(Account account);

    String getNum(@Param("account")Account account,@Param("itemId")String itemId);

    void insertCart(@Param("account") Account account,@Param("itemId") String itemId);

    void deleteCart(@Param("account") Account account,@Param("itemId") String itemId);

    void clearUpCart(@Param("account")Account account);

    void minusCart(@Param("account")Account account, @Param("itemId") String itemId);

    void addIteminCart(@Param("account")Account account, @Param("itemId")String itemId);

    String isExit(@Param("account")Account account, @Param("itemId")String itemId);

    String getPrice(@Param("itemId")String itemId);

}
